<form id="edit-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="">

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Customer_id')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-customer_id" data-rule="required" data-source="kuerp/customers/index" disabled class="form-control selectpage" data-search-field="customer_name,customer_code" data-field="customer_name" name="row[customer_id]" type="text" value="{$row.customer_id|htmlentities}">
            <input type="hidden" name="row[customer_id]" value="{$row.customer_id}">
        </div>
    </div>
    <!-- <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Relation_type')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-relation_type" class="form-control" name="row[relation_type]" type="text" value="{$row.relation_type|htmlentities}">
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Relation_id')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-relation_id" class="form-control" name="row[relation_id]" type="number" value="{$row.relation_id|htmlentities}">
        </div>
    </div> -->
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Relation_process')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-relation_process" class="form-control" readonly name="row[relation_process]" type="text" value="{$row.relation_process|htmlentities}">
        </div>
    </div>
    <!-- <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Event_id')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-event_id" class="form-control" name="row[event_id]" type="number" value="{$row.event_id|htmlentities}">
        </div>
    </div> -->
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Location')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-location" class="form-control" readonly name="row[location]" type="text" value="{$row.location|htmlentities}">
            {if condition="$row.lng" }
            <a href="https://apis.map.qq.com/uri/v1/marker?marker=coord:{$row.lat},{$row.lng};title:{$row.location};addr:{$row.location}&referer=crm" target="_blank" ><i class="fa fa-map-marker text-blue" style="font-size: 18px;margin-right:4px"></i>{$row.location|htmlentities}</a>
            {/if}
        </div>
    </div>
    <!-- <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Lng')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-lng" class="form-control" readonly name="row[lng]" type="text" value="{$row.lng|htmlentities}">
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Lat')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-lat" class="form-control" readonly name="row[lat]" type="text" value="{$row.lat|htmlentities}">
        </div>
    </div> -->
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Distance')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-distance" class="form-control" readonly name="row[distance]" type="text" value="{$row.distance|htmlentities}">
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('File_ids')}:</label>
        <div class="col-xs-12 col-sm-8">
            <ul class="row list-inline faupload-preview" id="p-goods_image">
                {foreach name="$row['file_ids_arr']" item="vo"}
                <li class="col-xs-3"><a href="{$vo}" data-url="{$vo}" target="_blank" class="thumbnail">
                    <img src="{$vo}" onerror="this.src='/gPNfUJHGAm.php/ajax/icon?suffix=png';this.onerror=null;" class="img-responsive"></a>
                </li>
                {/foreach}
            </ul>
            <!-- <input id="c-file_ids" class="form-control" name="row[file_ids]" type="text" value="{$row.file_ids|htmlentities}"> -->
            <input type="hidden" name="row[file_ids]" value="{$row.file_ids}">
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Content')}:</label>
        <div class="col-xs-12 col-sm-8">
            <textarea id="c-content" class="form-control editor" rows="5" name="row[content]" cols="50">{$row.content|htmlentities}</textarea>
        </div>
    </div>
    <!-- <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Staff_id')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-staff_id" class="form-control" name="row[staff_id]" type="number" value="{$row.staff_id|htmlentities}">
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Reminds_id')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-reminds_id" class="form-control" name="row[reminds_id]" type="text" value="{$row.reminds_id|htmlentities}">
        </div>
    </div> -->
    
    <!-- <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Working_time')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-working_time" class="form-control datetimepicker" data-date-format="YYYY-MM-DD HH:mm:ss" data-use-current="true" name="row[working_time]" type="text" value="{:$row.working_time?datetime($row.working_time):''}">
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Trip_distance')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-trip_distance" class="form-control" name="row[trip_distance]" type="number" value="{$row.trip_distance|htmlentities}">
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Other')}:</label>
        <div class="col-xs-12 col-sm-8">
            <textarea id="c-other" class="form-control " rows="5" name="row[other]" cols="50">{$row.other|htmlentities}</textarea>
        </div>
    </div> -->
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Next_time')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-next_time" class="form-control datetimepicker" data-date-format="YYYY-MM-DD HH:mm:ss" data-use-current="true" name="row[next_time]" type="text" value="{$row.next_time}">
        </div>
    </div>
    <div class="form-group layer-footer">
        <label class="control-label col-xs-12 col-sm-2"></label>
        <div class="col-xs-12 col-sm-8">
            <button type="submit" class="btn btn-primary btn-embossed disabled">{:__('OK')}</button>
        </div>
    </div>
</form>
